import request from '@/utils/request'

function uploadFileOss(data) {
  return request({
    url: '/lejuAdmin/material/uploadFileOss',
    method: 'post',
    data
  })
}

function addArticle(data) {
  return request({
    url: '/lejuAdmin/productArticle/addArticle',
    method: 'post',
    data
  })
}

function productArticle(id) {
  return request({
    url: `/lejuAdmin/productArticle/productArticle/${id}`
  })
}

function updateArticle(data) {
  return request({
    url: '/lejuAdmin/productArticle/updateArticle',
    method: 'post',
    data
  })
}

export {
  uploadFileOss,
  addArticle,
  productArticle,
  updateArticle
}
